In [1]:
from chemlab.io import remotefile
df = remotefile('https://raw.githubusercontent.com/cclib/cclib/master/data/GAMESS/basicGAMESS-US2012/water_mp2.out', 'gamess')
molecule = df.read('molecule')
mocoeffs = df.read('mocoeffs')
gbasis = df.read('gbasis')
In [2]:
from chemlab.qc import molecular_orbital
coefficients = mocoeffs[0][2]
f = molecular_orbital(molecule.r_array, coefficients, gbasis)
print(f(0, 1, 0))
In [3]:
from chemview import enable_notebook, MolecularViewer
enable_notebook()
import numpy as np
mv = MolecularViewer(molecule.r_array, { 'atom_types': molecule.type_array })
mv.ball_and_sticks(ball_radius=0.01)
mv.add_isosurface(f, isolevel=0.3, color=0xff0000, resolution=64)
mv.add_isosurface(f, isolevel=-0.3, color=0x0000ff, resolution=64)
mv
In [ ]: